import { get, post } from "./http"

//注册
export const reqRegister = params => post("/api/register", params)
//登录
export const reqlogin = params => post("/api/login", params)

//新人专享
export const reqgetnews = () => get("/api/getnew")
//万人团
export const reqgetgroupon = () => get("/api/getgroupon") 
//倒计时
export const reqgetcountdown = () => get("/api/getcountdown") 
//秒杀
export const reqgetseckill = () => get("/api/getseckill") 
//获取商品信息首页
export const reqgetindexgoods = () => get("/api/getindexgoods") 
//获取商品分类
export const reqgetcate = () => get("/api/getcate") 
//获取分类商品
export const reqgetgoods = (params) => get("/api/getgoods",params) 
//获取优惠券
export const reqgetcoupon = () => get("/api/getcoupon") 
//商品详情
export const reqgetgoodsinfo = (params)=>get('/api/getgoodsinfo',params)
//购物车列表
export const reqcartlist = (params) => get("/api/cartlist",params) 
//购物车添加
export const reqcartadd = (params) => post("/api/cartadd",params) 
//购物车删除
export const reqcartdelete = (params) => post("/api/cartdelete",params)

export const reqcartedit = (params) => post("/api/cartedit",params) 
//轮播图
export const reqgetbanner = () => get("/api/getbanner") 
